package models

import (
	"github.com/goravel/framework/database/orm"
)

// 地雷击杀
type MineLog struct {
	orm.Model
	ActionTime      string         `gorm:"column:action_time;type:varchar(255);not null" form:"action_time" json:"action_time"`
	UserId          int            `gorm:"column:user_id;type:int;not null" form:"user_id" json:"user_id"`
	UserName        string         `gorm:"column:user_name;type:varchar(255);not null" form:"user_name" json:"user_name"`
	StreamId        string         `gorm:"column:stream_id;type:varchar(255);not null" form:"stream_id" json:"stream_id"`
	Type            string         `gorm:"column:type;type:varchar(255);not null" form:"type" json:"type"`
	MineType        string         `gorm:"column:mine_type;type:varchar(255);not null" form:"mine_type"  json:"mine_type"`
	Location        string         `gorm:"column:location;type:varchar(255);not null" form:"location" json:"location"`
	OwnerName       string         `gorm:"column:owner_name;type:varchar(255);not null" form:"owner_name" json:"owner_name"`
	OwnerId         int            `gorm:"column:owner_id;type:int;not null" form:"owner_id" json:"owner_id"`
	OwnerStreamId   string         `gorm:"column:owner_stream_id;type:varchar(255);not null" form:"owner_stream_id" json:"owner_stream_id"`
	OriginalText    string         `gorm:"column:original_text;type:text;not null;comment:'原文'" json:"original_text"`
	ConfigurationID int            `gorm:"column:configuration_id;type:int;null" form:"configuration_id" json:"configuration_id"`
	Configuration   *Configuration `gorm:"foreignkey:ConfigurationID" form:"-" json:"-"`
}

// 表名
func (MineLog) TableName() string {
	return "minelogs"
}
